﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;
using LCA.Community.DAL.Model;

namespace LCA.Community.DAL.Interfaces
{
    /// <summary>
    /// The interface for the store service context.
    /// </summary>
    public interface IStorageServiceContext<T> where T : BasicStorageModel
    {
        /// <summary>
        /// Adds the specified object.
        /// </summary>
        /// <param name="stream">The stream.</param>
        /// <param name="name">The name.</param>
        void Add(T entity);
        /// <summary>
        /// Deletes the specified obkect.
        /// </summary>
        /// <param name="name">The name.</param>
        void Delete(T entity);
        /// <summary>
        /// Gets the URL of an object.
        /// </summary>
        /// <param name="name">The name.</param>
        Uri GetUrl(T entity);
        /// <summary>
        /// Check if the specified entity exists.
        /// </summary>
        /// <param name="entity">The entity.</param>
        /// <returns></returns>
        bool Exist(T entity);
        /// <summary>
        /// Gets or sets the base URL.
        /// </summary>
        /// <value>
        /// The base URL.
        /// </value>
        Uri BaseURL { get; }
    }
}
